Skip to content

feat(doctor): check for Java (javac) as an optional tool - #668

Open
yadavchiragg wants to merge 1 commit into
ControlCore-Project:devfrom
yadavchiragg:feat/doctor-java-check
Open

yadavchiragg wants to merge 1 commit into
ControlCore-Project:devfrom
yadavchiragg:feat/doctor-java-check

Conversation

@yadavchiragg

Copy link
Copy Markdown

What

Adds Java (javac) to concore doctor as an optional tool.

Why

mkconcore.py supports Java nodes (JAVACEXE/JAVACWIN/JAVAEXE/JAVAWIN, concore.java,
Dockerfile.java), but doctor did not check for a JDK, so a missing JDK only showed up
as a failure during build.

Details

  • A missing JDK is reported as a warning (same as MATLAB/Verilog/Docker), not an error.
  • Doctor also confirms javac actually runs. On macOS without a JDK, /usr/bin/javac is a
    stub that exists on PATH but exits non-zero, so a PATH check alone reports Java as present.
  • The optional-tool list is now an OPTIONAL_TOOLS constant instead of an inline tuple.
  • Added tests for: tool definition, config keys matching mkconcore.py, missing javac,
    failing stub javac, and working javac.

Testing

  • pytest tests/test_doctor.py tests/test_setup.py passes.
  • ruff format and ruff check are clean.
  • Manually checked concore doctor on macOS (Apple Silicon, Python 3.14): Java shows as a warning.
  • Note: tests/test_shm_abort.py and tests/test_shm_lifecycle.py (6 tests) fail on macOS both
    before and after this change. They are unrelated and I have left them alone.

@github-actions

Copy link
Copy Markdown

🎉 Welcome aboard, @yadavchiragg! Thank you for your first pull request in concore.

Please ensure that you are contributing to the dev branch.

Your contribution means a lot to us. We'll review it shortly.

Please ensure you have reviewed our:

If you have any questions, feel free to ask. Happy coding!

@yadavchiragg
yadavchiragg changed the base branch from main to dev November 12, 2026 05:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant